package com.example.mrzhou.lvmm.view.fragment.us;


import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.view.View;
import android.webkit.WebSettings;
import android.webkit.WebView;

import com.example.mrzhou.lvmm.R;
import com.example.mrzhou.lvmm.commom.base.BaseFragment;
import com.example.mrzhou.lvmm.commom.utils.WebSetUtils;

import butterknife.BindView;
import butterknife.ButterKnife;

/**
 * A simple {@link Fragment} subclass.
 */
public class UsFragment extends BaseFragment {

    public static final String WEB_URL = "http://m.lvmama.com/";
    @BindView(R.id.web_us)
    WebView webUs;

    public UsFragment() {
        // Required empty public constructor
    }

    public static UsFragment newInstance() {

        Bundle args = new Bundle();

        UsFragment fragment = new UsFragment();
        fragment.setArguments(args);
        return fragment;
    }

    @Override
    protected int getLayout() {
        return R.layout.fragment_us;
    }

    @Override
    protected void initView(View view) {
        ButterKnife.bind(this, view);
        initData();
    }

    @Override
    protected void initData() {
        WebSettings settings = webUs.getSettings();
        WebSetUtils.getInstance().webSetting(settings);
        webUs.loadUrl(WEB_URL);
    }

}
